package com.suny.lock;

/**
 * @author sunny
 * @date 2019/4/24
 */
public class SyncClass {
    private int x;

    public  void reduceA() {
        System.out.println("aaa");
    }

    public void reduceB() {
        synchronized (this) {
            x += 1;
        }
    }
}

